package cn.iocoder.moyun.module.curd.dal.dataobject.stringtext;

import cn.iocoder.moyun.framework.tenant.core.db.TenantBaseDO;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.time.LocalDateTime;

/**
 * 管理后台的用户 DO
 */
@TableName(value = "curd_string", autoResultMap = true)
@Data
@EqualsAndHashCode(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class StringTextDO extends TenantBaseDO {
    @Schema(description = "用户ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @ExcelProperty("用户ID")
    private Long id;

    @Schema(description = "合并后的业务字段", requiredMode = Schema.RequiredMode.REQUIRED, example = "{\"username\":\"admin\",\"nickname\":\"管理员\"}")
    @ExcelProperty("用户信息")
    private String text;

    @Schema(description = "最后登录IP", example = "192.168.1.1")
    @ExcelProperty("最后登录IP")
    private String loginIp;

    @Schema(description = "最后登录时间", example = "2023-01-01 12:00:00")
    @ExcelProperty("最后登录时间")
    private LocalDateTime loginDate;
}
